/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package be;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Embeddable;
import javax.validation.constraints.NotNull;

/**
 *
 * @author yzavaleta
 */
@Embeddable
public class PlantillaoperacionPK implements Serializable {
    @Basic(optional = false)
    @NotNull
    @Column(name = "id_planilla_operac")
    private int idPlanillaOperac;
    @Basic(optional = false)
    @NotNull
    @Column(name = "proceso_id")
    private int procesoId;
    @Basic(optional = false)
    @NotNull
    @Column(name = "planilla_id")
    private int planillaId;

    public PlantillaoperacionPK() {
    }

    public PlantillaoperacionPK(int idPlanillaOperac, int procesoId, int planillaId) {
        this.idPlanillaOperac = idPlanillaOperac;
        this.procesoId = procesoId;
        this.planillaId = planillaId;
    }

    public int getIdPlanillaOperac() {
        return idPlanillaOperac;
    }

    public void setIdPlanillaOperac(int idPlanillaOperac) {
        this.idPlanillaOperac = idPlanillaOperac;
    }

    public int getProcesoId() {
        return procesoId;
    }

    public void setProcesoId(int procesoId) {
        this.procesoId = procesoId;
    }

    public int getPlanillaId() {
        return planillaId;
    }

    public void setPlanillaId(int planillaId) {
        this.planillaId = planillaId;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (int) idPlanillaOperac;
        hash += (int) procesoId;
        hash += (int) planillaId;
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof PlantillaoperacionPK)) {
            return false;
        }
        PlantillaoperacionPK other = (PlantillaoperacionPK) object;
        if (this.idPlanillaOperac != other.idPlanillaOperac) {
            return false;
        }
        if (this.procesoId != other.procesoId) {
            return false;
        }
        if (this.planillaId != other.planillaId) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "be.PlantillaoperacionPK[ idPlanillaOperac=" + idPlanillaOperac + ", procesoId=" + procesoId + ", planillaId=" + planillaId + " ]";
    }
    
}
